<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
  <head>
    <title>Week4-Question4</title>
	    <script type="text/javascript" src="https://maps.google.com/maps/api/js?key=AIzaSyDRxymu3G5nFQuVp3f573YfU3VvERK6tCk&sensor=false">
	    </script>
	    
	    <script type="text/javascript">
	    	 var lanLng = null;
	    	 var locations = [
	    	  ['UTS Main Building', -33.8839, 151.2007],
				  ['1 Bay St. Broadway', -33.88367, 151.194448],
				  ['Eddy Avenue entrance to Central Station', -33.882541, 151.207492],
				  [' FEIT Building 10 - 10 Jones St. Broadway', -33.883617, 151.199668]
				];

	    	function initialize(){
		         latlng = new google.maps.LatLng(-33.8839, 151.2007);
		         var myOptions = {
		         zoom: 15,
		         center: latlng,
		      	 mapTypeId: google.maps.MapTypeId.ROADMAP
		    		}
		   	 var map = new google.maps.Map(document.getElementById("map_canvas"), myOptions);
		  		
		   	 for(var i = 0; i< locations.length; i++){
		   	 	  latlng = new google.maps.LatLng(locations[i][1], locations[i][2]);
			   	 	var marker = new google.maps.Marker({
			      position: latlng,
			      title: locations[i][0],
			      map: map
			  		}); 
		   	 }
	 	  
	    	}
	    </script>
	</head>
	<body onload="initialize()">
		<div id="map_canvas" style="width: 500px; height: 500px"></div>
	</body>
</html>